package com.example.springbootjdbc.config;

import org.springframework.beans.factory.annotation.Value;
import org.springframework.boot.context.properties.ConfigurationProperties;

/**
 * @ClassName JdbcProperties
 * @Description JdbcProperties JDBC配置信息属性类
 * @Author ZX
 * @Date 2020/5/26
 */
//@ConfigurationProperties(prefix = "jdbc")  //无法读取自定义的配置文件，只能读取默认的配置文件
public class JdbcProperties { //属性名必须与配置文件中一致，必须提供set方法

    private  String driverClassName;
    private  String username;
    private  String password;
    private  String url;

    public String getDriverClassName() {
        return driverClassName;
    }

    public void setDriverClassName(String driverClassName) {
        this.driverClassName = driverClassName;
    }

    public String getUsername() {
        return username;
    }

    public void setUsername(String username) {
        this.username = username;
    }

    public String getPassword() {
        return password;
    }

    public void setPassword(String password) {
        this.password = password;
    }

    public String getUrl() {
        return url;
    }

    public void setUrl(String url) {
        this.url = url;
    }
}
